package ${package.AddParam}.${entity?uncap_first};

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.*;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;
import java.time.LocalDateTime;
/**
 * <p>
 * ${table.comment!}新增时数据内容
 * </p>
 *
 * @author ${author}
 * @since ${date}
 */
@Data
@ApiModel
public class ${entity}AddParam {

<#-------------  BEGIN 字段循环遍历  ---------->
<#list table.fields![] as field>
    @ApiModelProperty(value = "${field.comment!},长度${(field.metaInfo.length)!}")
    <#if field.propertyType == "String">
    @NotBlank(message = "${field.propertyName}不能为空")
    @Size(max = ${(field.metaInfo.length)!}, message = "${field.propertyName}最大长度为${(field.metaInfo.length)!}")
    <#else>
    @NotNull(message = "${field.propertyName}不能为空")
    </#if>
    private ${field.propertyType} ${field.propertyName};

</#list>
<#------------  END 字段循环遍历  ---------->
}
